#ifndef __LOGO_ERROR_DLG_H__
#define __LOGO_ERROR_DLG_H__

#include "resource.h"
#include "SimpleWnd/SimpleWnd.h"
#include "SimpleWnd/GridCtrl.h"

#define ADD_ERROR       (WM_USER+600) /* wParam is the pointer to string*/
#define SHOW_DLG        (WM_USER+601)
#define HIDE_DLG        (WM_USER+602)
#define DEL_ERRORS      (WM_USER+603)

class CErrorLogDlg : public CDialog  
{
public:
   CErrorLogDlg();

	BEGIN_MSG_MAP(CErrorLogDlg)
      MESSAGE_HANDLER(ADD_ERROR, OnAddError)
      MESSAGE_HANDLER(SHOW_DLG, OnShowDlg)
      MESSAGE_HANDLER(HIDE_DLG, OnHideDlg)
      MESSAGE_HANDLER(DEL_ERRORS, OnDelErrors)
		MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
      MESSAGE_HANDLER(WM_CLOSE, OnClose)
		COMMAND_ID_HANDLER(IDOK, OnOK)
	END_MSG_MAP()

	DIALOG_ID(IDD_ERROR);

protected:
	LRESULT OnInitDialog(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
	LRESULT OnOK(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled);
   LRESULT OnAddError(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
   LRESULT OnDelErrors(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
   LRESULT OnShowDlg(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
   LRESULT OnHideDlg(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);
   LRESULT OnClose(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled);

   CGridCtrl   m_ctlGrid;
   bool        m_bVisible;
};


#endif
